Skip to content

[controls] use shared component for "Values preview" for data control and variable control - #290657

Open
nreese wants to merge 34 commits into
elastic:mainfrom
nreese:issue_274439
Open

nreese wants to merge 34 commits into
elastic:mainfrom
nreese:issue_274439

Conversation

@nreese

@nreese nreese commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

Closes #274439

PR resolves issue by creating a shared component that is used by both control and variable control editor to ensure both components display same information. Created new package for shared component.

Test instructions

  • Install sample web logs
  • Create dashboard
  • Add variable control with ESQL statement FROM kibana_sample_data_logs | STATS BY machine.os.keyword.
  • Add control. Click "write a query" and use FROM kibana_sample_data_logs | STATS BY machine.os.keyword
  • Ensure "Values preview" shows filter pills for each
  • Try ESQL parse error, set query to not valid. Ensure compile error is displayed
  • Try query that does not return any values. Set query to FROM kibana_sample_data_logs | where bytes < -1
  • Try query that returns multiple columns. Set query to FROM kibana_sample_data_logs | STATS BY machine.os.keyword, bytes

@infra-vault-gh-plugin-prod

Copy link
Copy Markdown
🤖 Jobs for this PR can be triggered through checkboxes. 🚧

ℹ️ To trigger the CI, please tick the checkbox below 👇

  • Click to trigger kibana-pull-request for this PR!
  • Click to trigger kibana-deploy-project-from-pr for this PR!
  • Click to trigger kibana-deploy-cloud-from-pr for this PR!
  • Click to trigger kibana-entity-store-performance-from-pr for this PR!
  • Click to trigger kibana-storybooks-from-pr for this PR!

@nreese

nreese commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 11, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 14, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 14, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 14, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 14, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 14, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese

nreese commented Sep 14, 2026

Copy link
Copy Markdown
Contributor Author

/ci

@nreese
nreese marked this pull request as ready for review September 14, 2026 19:42
@nreese
nreese requested review from a team as code owners September 14, 2026 19:42
@nreese nreese added Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas t// release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting v9.6.0 labels Sep 14, 2026
@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

Pinging @elastic/kibana-presentation (Team:Presentation)

@stratoula
stratoula self-requested a review September 15, 2026 06:36
@akowalska622

Copy link
Copy Markdown
Contributor

I didn't check the code yet, but tested locally and seems like I can't run those steps

Try query that does not return any values. Set query to FROM kibana_sample_data_logs | where bytes < -1
Try query that returns multiple columns. Set query to FROM kibana_sample_data_logs | STATS BY machine.os.keyword, bytes

The test instructions don't specify what should be displayed (I'd expect some warnings), but it looks to me like it's stuck on a previous search. Am I doing something wrong while testing or it's a real implementation bug?

Attaching video

Screen.Recording.2026-09-15.at.10.06.53.mov

@akowalska622

Copy link
Copy Markdown
Contributor

I also see that @stratoula assigned herself to the review, I'll continue testing and review regardless, but I'll leave the final approve for her!

@kibanamachine

kibanamachine commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

💔 Build Failed

Failed CI Steps

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
controls 133.9KB 133.8KB -61.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
shared-plugins 12.2MB 12.1MB -1.9KB
Unknown metric groups

shared async chunks total size

id before after diff
all 15.0MB 15.0MB +936.0B

total optimizer output size

id before after diff
all 63.9MB 63.9MB -1.1KB

Test Failures

  • [job] [logs] Jest Tests #14 / ConnectorsForm changes to a new corrector correctly and its fields correctly
  • [job] [logs] Scout Lane #114 - serverless-observability_complete / default / local-serverless-observability_complete - Synthetics manage rules privilege - lets a read user with can_manage_rules enable default alerting
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact list page — Blocklist - T1 analyst sees no privileges on the list page
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Blocklist - ALL user can assign and remove artifacts from the policy
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Blocklist - ALL user can manage and assign unassigned artifacts
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Event Filters - ALL user can add an artifact from an empty tab
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Event Filters - ALL user can manage and assign unassigned artifacts
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Host isolation exceptions - Tab is hidden when the user has no artifact privilege
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Trusted applications - Tab is hidden when the user has no artifact privilege
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Artifact tabs in Policy Details page — Trusted devices - Tab is hidden when the user has no artifact privilege
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - blocked internal saved objects API - post /api/saved_objects/_bulk_create returns 400
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - capabilities - returns a 400 when an invalid app id is provided
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - compression - uses compression when there is no referer
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - global.teardown.ts - Delete leftover agnostic endpoint artifact lists and field-caps seed docs
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Maps - Full screen mode
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - Painless Lab - runs a script, navigates the panels, and views the request without a11y violations
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - translations - returns the translations with the correct headers
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - ui settings CRUD - returns list of settings
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - ui settings validate - returns validation error for invalid value
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - xsrf protection Authorization-scheme bypass (server.xsrf.allowedSchemes) - accepts a self-invalidation request authenticated with a real ApiKey Authorization header and no kbn-xsrf header
  • [job] [logs] Scout Lane #130 - serverless-security_complete / default / local-serverless-security_complete - xsrf protection Authorization-scheme bypass (server.xsrf.allowedSchemes) - rejects the same request when authenticated with a cookie session (no Authorization-header scheme), even with the bypass enabled
  • [job] [logs] Scout Lane #25 - stateful-classic / default / local-stateful-classic - Synthetics manage rules privilege - lets a read user with can_manage_rules enable default alerting

History

@nreese

nreese commented Sep 15, 2026

Copy link
Copy Markdown
Contributor Author

The test instructions don't specify what should be displayed (I'd expect some warnings), but it looks to me like it's stuck on a previous search. Am I doing something wrong while testing or it's a real implementation bug?

This is an issue with the variables control component not clearing the previous error when the next query does not have one column. Resolved with 2ea14f1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas t// v9.6.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ES|QL Controls] Merge aesthetic improvements from data control pre-filtering into the variable control editor

3 participants